package com.information.manage.basic.audit.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.information.manage.basic.audit.model.entity.AuditModelDO;
import com.information.manage.basic.common.result.Result;
import com.information.manage.basic.audit.model.query.AddAuditModelQuery;
import com.information.manage.basic.audit.model.query.AuditModelQuery;
import com.information.manage.basic.audit.model.query.UpdateAuditModelQuery;

import javax.servlet.http.HttpServletRequest;

public interface AuditModelService extends IService<AuditModelDO> {

    /**
     * 创建审核模板
     * @param addAuditModelQuery
     * @return
     */
    Result createAuditTemplate(AddAuditModelQuery addAuditModelQuery, HttpServletRequest request);

    /**
     * 获取审核模板分页
     *
     * @param auditModelQuery
     * @return
     */
    Result getAuditTemplatesPage(AuditModelQuery auditModelQuery);

    /**
     * 获取审核模板详情
     *
     * @param id
     * @return
     */
    Result getAuditTemplateById(Long id);

    /**
     * 更新审核模板
     *
     * @param updateAuditModelQuery
     * @return
     */
    Result updateAuditTemplate(HttpServletRequest request, UpdateAuditModelQuery updateAuditModelQuery);

    /**
     * 应用审核模板
     *
     * @param id
     * @return
     */
    Result applyAuditTemplate(Long id, HttpServletRequest request);

    /**
     * 停用审核模板
     *
     * @param id
     * @return
     */
    Result stopAuditTemplate(Long id, HttpServletRequest request);

    /**
     * 删除审核模板
     *
     * @param id
     * @return
     */
    Result deleteAuditTemplate(Long id);

    AuditModelDO readApplyAuditTemplate();


}
